package com.tang.controller;

import com.tang.sys.ResponseResult;
import com.tang.sys.entity.Talk;
import com.tang.sys.service.ITalkService;
import com.tang.sys.service.IUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/talk")
public class BlogTalkController {

    @Autowired
    private ITalkService iTalkService;
    @Autowired
    private IUserService iUserService;


    @GetMapping("/talkList")
    public ResponseResult talkList(Integer pageNum, Integer pageSize, Talk talk){

        return iTalkService.talkList(pageNum,pageSize,talk);
    }
    @GetMapping("/talkUser")
    public ResponseResult talkUser(){

        return iUserService.talkUser();
    }
}
